package com.testDemo.hutool;

import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.collection.ListUtil;
import com.google.common.collect.Lists;
import org.apache.commons.collections.CollectionUtils;
import org.junit.jupiter.api.Test;

import java.util.*;

/**
 * @author : zouren
 * @date : 2020/4/13 10:04
 */
public class CollectionUtilTest {
    @Test
    public void test() {
        List list = new ArrayList();
        System.out.println(list.toString());
        System.out.println(CollectionUtil.isNotEmpty(list));

    }
    @Test
    public void test1() {
         List<String> beanTimeOperator = Lists.newArrayList( "create_operator", "create_time", "modify_operator", "modify_time");

        List<String> columList = Lists.newArrayList("id","create_operator","modify_operator","create_time","modify_time");

        List<String> list3 = (List<String>) CollectionUtils.intersection(columList, beanTimeOperator);
        ListUtil.sortByPinyin(list3);

        System.out.println(list3.equals(beanTimeOperator));

    }

}
